package com.example.demo.mapper;

import com.example.demo.dto.Permission;
import com.example.demo.dto.Role;
import com.example.demo.dto.User;
import com.example.demo.entity.SysUser;

import java.util.List;

public interface SysUserMapper {
    int deleteByPrimaryKey(Long id);

    int insert(SysUser record);

    int insertSelective(SysUser record);

    SysUser selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(SysUser record);

    int updateByPrimaryKey(SysUser record);

    User findByName(String name);
    List<Role> findRoleByUserId(Long userId);
    List<Permission> findPermissionByRoleId(Long roleId);
}